/**
 * 应用的核心js文件
 */
var grApp = angular.module('gr-app', ['toaster', 'ngAnimate']);

//绑定了产品操作的控制器
grApp.controller('ProductCtrl',['$scope','$http',function($scope,$http){
    //$scope.count = 10;
    //$scope.row = 200;
    //$scope.more = function(args){
    //    $scope.count++;
    //    $scope.row = $scope.row + '10';
    //}
    //$scope.more1 = function(){
    //    ////触发一段ajax请求
    //    $http.get("/api1/api/things1/").success(function(res){
    //        $scope.code = res.code;
    //    });
    //    ////alert(11);
    //};
    $scope.test = function(){
        alert('3');
        $scope.count++;
    }
}]);

grApp.controller('DetailCtrl',function($scope,$http){
    $scope.price=1;
    $scope.more = function(args){
        window.alert(args);

        $scope.price ++;
    }
    $scope.more1 = function(){
        ////触发一段ajax请求
        //$http.get("http://localhost:3000/p/l/grrm/1").success(function(res){
        //    console.log(res);
        //});
        ////alert(11);
    };
});

//
//grApp.controller('AddrCtrl',['$scope','$http',function($scope,$http){
//    $http.get("/user/center/address").success(function(res){
//
//    });
//    $scope.addAddress = function(){
//        location.href=('addAddress');
//    };
//    $scope.editAddress = function(){
//        location.href=('addAddress');
//
//    }
//    $scope.deleteAddress = function(){
//        addressCtrl.aa();
//    }
//    $scope.setDefault = function(){
//        alert('set');
//    }
//}]);

/*@ start to scor*/

/*@ end to scor*/
